home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 October: Technology Seed / ADC Seed CD - October 1999.toast / FireWire / FireWire_2.1_SDK_DR3 / Source / FWiX / FWiXApp / FWiXprefs.h < prev   
Encoding:
Text File  |  1999-05-17  |  1.6 KB  |  85 lines  |  [TEXT/MPS ]

  1. /*
  2.     File:        FWiXprefs.h
  3.  
  4.     Contains:    Declarations for prefs handling.
  5.  
  6.     Written by:    Jay Lloyd
  7.     
  8.     Copyright:    © 1996-1997 by Apple Computer, Inc., all rights reserved.
  9.  
  10.     Writers:
  11.  
  12.         (jkl)    Jay Lloyd
  13.  
  14.     Change History (most recent first):
  15.  
  16.        <FW2>      5/7/97    jkl        Nothing really.
  17.        <FW1>     3/18/97    jkl        first checked in
  18. */
  19.  
  20. enum
  21. {
  22.     kPrefsResourceType        = 'prfs',
  23.     kWinPosPrefsType        = 'win ',
  24.     kWinPosPrefsID            = 128,
  25.     kPrefsResourceID        = 128,
  26.     kSndPrefsResourceID        = 129,
  27.     kDropPrefsResourceID    = 130,
  28.     kPrefsFileResourceID    = 131,
  29.  
  30.     kCustomGetFileResID        = 132,
  31.     kSelectItem                = 13,
  32.     kCustomGetUserItem        = 14
  33. };
  34.  
  35. static void    HandlePrefsDialogEvent (
  36.     DialogPtr                pDlog,
  37.     SInt16                    itemHit);
  38.     
  39. static OSErr GetDeskFolderSpec(
  40.     FSSpec                     *pFileSpec);
  41.  
  42. static pascal void DrawUserSelection(
  43.     WindowPtr                theWindow,
  44.     SInt16                    itemNo);
  45.  
  46. static pascal void DrawDefaultButton(
  47.     WindowPtr                theWindow,
  48.     SInt16                    itemNo);
  49.  
  50. static pascal Boolean HandlePrefsEventFilter(
  51.     DialogPtr                pDlog,
  52.     EventRecord                *pEvent,
  53.     SInt16                    *itemHit);
  54.     
  55. static OSErr SetupDialogPrefs (
  56.     DialogPtr                pDlog);
  57.  
  58. static OSErr UpdateDialogPrefs (
  59.     DialogPtr                pDlog);
  60.  
  61. static OSErr GetDropFolder (
  62.     StandardFileReply        *reply );
  63.     
  64. static pascal Boolean FilterAllFiles (
  65.     CInfoPBPtr                pb,
  66.     Ptr                        pMyData);
  67.  
  68. static pascal SInt16 DialogHook (
  69.     SInt16                    item,
  70.     DialogPtr                pDlog,
  71.     Ptr                        pMyData);
  72.  
  73. static Boolean SameFile (
  74.     FSSpec                    *spec1,
  75.     FSSpec                    *spec2);
  76.  
  77. static void SetSelectButtonName (
  78.     FSSpec                    *spec,
  79.     DialogPtr                theDlg);
  80.  
  81. static void AppendStrToStr (
  82.     StringPtr                dst,
  83.     StringPtr                src,
  84.     UInt8                    maxDstLen);
  85.